package com.ynet.middleground.mobile.approve.mq;

import org.springframework.cloud.stream.annotation.Input;
import org.springframework.cloud.stream.annotation.Output;
import org.springframework.messaging.MessageChannel;
import org.springframework.messaging.SubscribableChannel;

/**
 * 项目名：ifp-mobile-approve <br>
 * 包名：com.ynet.middleground.mobile.approve.mq <br>
 * 类名：SourceMobileApprove <br>
 * 描述：
 *
 * @author Suremotoo
 * @create 2021-03-24 21:43
 */
public interface SourceMobileApprove {

    String JKZTYDSP_TO_BLXD_SPCZ = "jkztydsp_to_blxd_spcz";

    String BLXD_TO_JKZTYDSP_QDSPJGXX = "blxd_to_jkztydsp_qdspjgxx";

    String JKZTYDSP_TO_BLXD_FSFKYZM = "jkztydsp_to_blxd_fsfkyzm";

    /**
     * 往 MQ 推送审批操作执行前的通知，由渠道订阅消费
     *
     * @return
     */
    @Output(SourceMobileApprove.JKZTYDSP_TO_BLXD_SPCZ)
    MessageChannel noticeApprove();

    /**
     * 往 MQ 推送需要发送放款验证码的通知，由渠道订阅消费
     *
     * @return
     */
    @Output(SourceMobileApprove.JKZTYDSP_TO_BLXD_FSFKYZM)
    MessageChannel noticeSendCaptcha();

    /**
     * 模拟渠道核心业务系统主动向移动审批推送审批结果信息同步数据<br>
     * 注意📢: 该消息推送为手动补偿使用，针对渠道无法推送消息时的备用方案
     *
     * @return
     */
    @Input(SourceMobileApprove.BLXD_TO_JKZTYDSP_QDSPJGXX)
    SubscribableChannel receiveChannelApproveStateManualCompensation();

}
